<?php
	
require_once("Activity.php");

class CreateActivity extends Activity
{
	public function __construct($title,$startTime,$endTime,$startDate,$endDate,$description,$event)
	{
		$this->title = $title;
		$this->startTime = $startTime;
		$this->endTime = $endTime;
		$this->startDate = $startDate;
		$this->endDate = $endDate;
		$this->description = $description;
		$this->event = $event;

		$this->db = new dbConn();
	}

	public function register()
	{
		$res = $this->db->insert("INSERT INTO activity (title,description,startDate,endDate,startTime,endTime,event)
								VALUES ('$this->title','$this->description','$this->startDate','$this->endDate','$this->starTime','$this->endTime',$this->event)");

		if($res)
		{
			return true;
		}
		else
		{
			return false;
		}
	}
}

?>